// Ryzom - MMORPG Framework <http://dev.ryzom.com/projects/ryzom/>
// Copyright (C) 2010  Winch Gate Property Limited
//
// This program is free software: you can redistribute it and/or modify
// it under the terms of the GNU Affero General Public License as
// published by the Free Software Foundation, either version 3 of the
// License, or (at your option) any later version.
//
// This program is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
// GNU Affero General Public License for more details.
//
// You should have received a copy of the GNU Affero General Public License
// along with this program.  If not, see <http://www.gnu.org/licenses/>.

#include "nel/misc/types_nl.h"
#include <list>
#include <time.h>
#include "nel/misc/time_nl.h"
#include "nel/misc/thread.h"
#include "nel/misc/random.h"
#include "nel/misc/singleton.h"
#include "nel/net/service.h"
#include "game_share/singleton_registry.h"

#include "logger_service.h"

#ifdef NL_OS_WINDOWS
#	define NOMINMAX
#	include <windows.h>
#endif // NL_OS_WINDOWS

using namespace std;
using namespace NLMISC;
using namespace NLNET;

// the logger service
class CLoggerService : public IService
{
public:

	/**
	 * Init
	 */
	void init()
	{
		CSingletonRegistry::getInstance()->init();
	}

	/**
	 * Update
	 */
	bool update ()
	{
		CSingletonRegistry::getInstance()->tickUpdate();

		return true;
	}

	void release()
	{
		CSingletonRegistry::getInstance()->release();

	}

};



/// Logger servive
//
NLNET_SERVICE_MAIN (CLoggerService, "LGS", "logger_service", 0, EmptyCallbackArray, "", "");
